package AbstractTest;

public abstract class Animal {
    String name;
    int age;

    public void eat(){
        System.out.println(name + "吃饭");
    }

    public double sleep(double hour){
        return hour * 3;
    }

    public Animal(String name, int age) {
        this.name = name;
        this.age = age;
    }

}
